import * as ax from './request';

export const url = ax.url + '/op'
// export const url = ax.url

export const getSuborderList = (params) => {
    return ax.g(url + '/suborders/self', params)
}

export const getSuborder = (params) => {
    return ax.g(url + '/suborders/' + params.id, params)
}

export const createSuborder = (params) => {
    return ax.p(url + '/suborders', params)
}

export const updateSuborder = (params) => {
    return ax.u(url + '/suborders/' + params.id, params)
}

export const delSuborder = (params) => {
    return ax.d(url + '/suborders/' + params.id, params)
}

export const suborderAction = (params) => {
  return ax.p(url + '/suborders/action', params)
}

export const initSuborderListInfo = () => {
  return ax.g(url + '/suborders/initSuborderListInfo')
}

export const initCountButtn = () => {
  return ax.g(url + '/suborders/count/all')
}
